﻿<UserControl x:Class="Kokomo.Environment.Documents.TreeDocumentView"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
			 xmlns:kmc="xaml://kokomo/ui"
			 xmlns:env="xaml://kokomo/environment"
             mc:Ignorable="d"
			 xmlns:doc="clr-namespace:Kokomo.Environment.Documents"
             d:DesignHeight="300" d:DesignWidth="300">
	<FrameworkElement.Resources>
		<DataTemplate DataType="{x:Type doc:TreeNodeViewModel}">
			<doc:TreeNodeView/>
		</DataTemplate>

		<!--<m:DataGridRowIndexConverter x:Key="RowIndexConverter"/>-->
	</FrameworkElement.Resources>

	<doc:NavigationView
		GoBackCommand="{Binding GoBackCommand}"
		GoForwardCommand="{Binding GoForwardCommand}"
		>
		<Grid>
			<Grid.ColumnDefinitions>
				<ColumnDefinition Width="200"/>
				<ColumnDefinition Width="*"/>
			</Grid.ColumnDefinitions>

			<Border
				Style="{DynamicResource {x:Static env:EditorStyleKeys.SectionBorderStyleKey}}"
				Margin="0 0 6 0"
				>
				<kmc:EnhancedTreeView
					ItemContainerStyle="{DynamicResource {x:Static env:EditorStyleKeys.TreeNodeStyleKey}}"
					ItemsSource="{Binding HeaderNodes}"
					SelectedObject="{Binding SelectedNode}"
					/>
			</Border>

			<GridSplitter Width="6" Background="Transparent"/>

			<doc:DetailView DataContext="{Binding CurrentDetailViewModel}" Grid.Column="1"/>
			<!--<Border
				Grid.Column="1"
				CornerRadius="6"
				Padding="6"
				Background="White"
				>
				<Border.Resources>
					<DataTemplate DataType="{x:Type pe:ProcedureViewModel}">
						<Border
							Background="White"
							CornerRadius="6"
							Padding="6"
							>
						</Border>
					</DataTemplate>
				
				</Border.Resources>
			
				<ContentPresenter Content="{Binding CurrentDetailViewModel}"/>
			</Border>-->
		</Grid>
	</doc:NavigationView>
</UserControl>
